Skip to content

Fix pinch-to-zoom on the canvas - #249

Merged
stevebauman merged 1 commit into
masterfrom
fix/canvas-pinch-zoom
Oct 14, 2026
Merged

stevebauman merged 1 commit into
masterfrom
fix/canvas-pinch-zoom

Conversation

@stevebauman

@stevebauman stevebauman commented Oct 14, 2026 •

Copy link
Copy Markdown
Owner

Trackpad pinch gestures weren't connected to the canvas zoom controls, so pinching could zoom the page instead of the canvas. Touchscreen pinches could resize the canvas, but left the zoom slider and saved viewport at their previous scale.

I've connected trackpad pinches to smooth zooming around the pointer and kept the controls and saved viewport in sync with gesture changes. Gestures use the same 20–200% range as the slider, work across the canvas area, and leave ordinary scrolling alone.

Verified with the full test suite (160 tests passing), the desktop renderer build, and the GitHub Actions test and Cloudflare production-build jobs.

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying showcode with  Cloudflare Pages  Cloudflare Pages

Latest commit: 78eff97
Status: ✅  Deploy successful!
Preview URL: https://67df2078.showcode.pages.dev
Branch Preview URL: https://fix-canvas-pinch-zoom.showcode.pages.dev

View logs

@stevebauman
stevebauman merged commit a34a3f6 into master Oct 14, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant